﻿using System;
using System.Collections.Generic;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Xml;
using VersionComparer.Properties;

namespace VersionComparer.DataModel.Xml
{
    public class XmlCommentItem: XmlItem
    {
        protected static Image commentImage = InitializeImage(VersionComparer.Images.ImageResources.Comment);
        public XmlCommentItem()
        {
        }
        public XmlCommentItem(ComparableItem item, XmlNode node)
            : base(item, node)
        {
        }

        protected override System.Drawing.Image GetImage()
        {
            return commentImage;
        }

        protected override void BuildRtf(Base.RtfBuilder builder, bool differencesOnly, bool useParentColor)
        {
            
            builder.Append("<!-- ", Color.Blue);
            builder.Append(XmlNode.InnerText, Color.Green);
            builder.AppendLine(" --> ", Color.Blue);
        }
    }
}
